<script setup lang="ts">

import { inject } from 'vue';

const LoadingService = inject('LoadingService');

let count = 0;
function ifLoading() {
    if (count % 2 === 0) {
        LoadingService.show('当前页面正在加载中...');
    } else {
        LoadingService.close();
    }
    count++;
}
</script>
<template>
    <f-button style="margin: 5px" @click="ifLoading"> 测试按钮 </f-button>
</template>
